/**
 * 小工单
 */
import { defineStore } from 'pinia';

export const useTicketStore = defineStore('ticket', {
	state: () => ({
		FCJType: null as any,

		// 工单列表排序
		ticket_sort: {} as any,
		defaultSort: null,

		// 派工单列表排序
		dispatch: {
			sort: {} as any,
			defaultSort: null
		},

		// 新建工单 - 工艺路线数据
		createTicket_routing: null as any,
		createTicket_Materials: null as any, // 新建工单 - 用料清单数据
		editDataInfo: {}, // 新增编辑环境 - 编辑的详情数据
	}),
	actions: {},
	getters: {},
	persist: {
		key: 'ticket-store',
		paths: [
			"ticket_sort",
			"dispatch",
			"FCJType"
		]
	}
})